package com.danco.training.zaneuskaya.client;

import java.io.IOException;

import java.net.InetAddress;
import java.net.Socket;
import java.net.UnknownHostException;

import com.danco.training.zaneuskaya.api.MenuController;
import com.danco.training.zaneuskaya.communication.MessageAnalyzer;
import com.danco.training.zaneuskaya.dependency.DependencyConfiguration;




public class MainClientThread {
	
	public static final int PORT = 1111;
	private static Socket client;
	private static MessageAnalyzer messageAnalyzer;
	
	
	public static void main(String[] args) throws UnknownHostException, IOException {
		
		client = new Socket(InetAddress.getLocalHost(),PORT);
		messageAnalyzer = new MessageAnalyzer(client);
	
		while (true){
			
			MenuController menuController = (MenuController) DependencyConfiguration.getInstanceByClassName(MenuController.class);
			menuController.runMenu();
		}
	}

	
}
